home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Wildcat Files 2
/
The Wildcat Files 2 (Arsenal Computer).ISO
/
qm-util
/
msi-mail.scr
< prev
next >
Wrap
Text File
|
1994-07-21
|
5KB
|
133 lines
;This is a script to make unattended mail runs from a BBS thru a batch file
;using Q-Modem Pro. You will need to "customize" this script to suit your
;needs. I would not recommend setting the redial limit more than 10 attempts
;otherwise, you will get an error "TOO MANY WHEN'S".
;
TURNON 8_BIT
TURNOFF LINEFEED
TURNOFF NOISE
TURNOFF MUSIC
TURNON SCROLL
TURNOFF PRINT
TURNOFF ECHO
TURNOFF SPLIT
TURNON STATUSLN
TURNOFF DOORWAY
STRING QWKFILE REPFILE QWKPATH REPPATH TELNUM LIMIT
STRING INITIAL DOOR XFER NAME HOSTNAME
ASSIGN HOSTNAME "MUSTANG SOFTWARE" ;The BBS you want to call
ASSIGN QWKFILE MUSTANG.QWK ;The name of .QWK packet
ASSIGN REPFILE MUSTANG.REP ;The name of the .REP packet
ASSIGN QWKPATH C:\QWK\ ;Your .QWK download directory
ASSIGN REPPATH C:\REP\ ;Your .REP upload directory
ASSIGN DOOR T ;Maybe "T" for TomCat
ASSIGN XFER Z ;Your download protocol
ASSIGN NAME "NAME Password" ;Your Node name and password
ASSIGN TELNUM "ATDT 1-805-873-2400^M";The BBS phone # you're calling
ASSIGN LIMIT 7 ;# of times you want to re-dial
ASSIGN INITIAL "AT&C1&D2E0^M" ;Your modem init. string
SETCOMM 19200 8 NONE 1
;---------------------------- Initialize the Modem ----------------------
INIT:
SEND "ATH0^M"
DELAY 1000
ASSIGN 0 $LIMIT
CLRSCR
DISPLAY "Initializing Modem ... "
DELAY 1000
SEND "$INITIAL"
WAITFOR "OK"
;----------------------------- Dial the Board ---------------------------
GETON:
WHEN "BUSY" AGAIN
WHEN "NO CARRIER" AGAIN
PAUSE 2000
DECR 0
IF "$0" < "1" GETOUT
TIMEOUT 75 GETON
CLRSCR
DISPLAYLN "Attempting to connect with $HOSTNAME"
DISPLAYLN "Dial attempts left are $0"
DISPLAYLN "Dialing string: $TELNUM"
DELAY 100
SEND "$TELNUM"
WAITFOR "CONNECT"
GOTO ONTHESYSTEM
AGAIN:
PAUSE 1000
SEND "ATH1^M"
PAUSE 5000
GOTO GETON
;-------------------- We have connected to the System ------------------
ONTHESYSTEM:
WHEN "first name" "*$NAME^M"
WHEN "ontinue, [" "C^M"
WHEN "view the bulletin menu" "N^M"
WHEN "[ENTER] to continue" "^M"
WHEN "NO CARRIER" GETOUT
TIMEOUT 600 GETOUT
SEND "^M"
WAITFOR "MAIN MENU"
DELAY 100
SEND "M^M"
DELAY 100
SEND "^M"
WAITFOR "MESSAGE MENU"
DELAY 100
SEND "$DOOR^M"
;-------------------- Call for the Download of the Mail Packet ---------
DOWNSECTION:
DL:
SEND "^M"
WAITFOR "wcMAIL COMMAND"
DELAY 100
SEND "D^M"
WHEN "to download!" UPSECTION
WHEN "NO CARRIER" GETOUT
WAITFOR "oodbye when done"
DELAY 1000
SEND "Y^M"
WHEN "Insufficient time" UPSECTION
WAITFOR "Start"
DELAY 100
DOWNLOAD $XFER $QWKPATH$QWKFILE
DELAY 200
;-------------------------- Lets Upload the Replies ---------------------
UPSECTION:
SEND "^M"
WHEN "NO CARRIER" GETOUT
SEND "^M"
WAITFOR "wcMAIL COMMAND"
DELAY 100
EXIST $REPPATH$REPFILE SENDEM
GOTO ALLDONE
SENDEM:
SEND "U^M"
DELAY 100
WAITFOR "Start"
PAUSE 1000
UPLOAD $XFER $REPPATH$REPFILE
WHEN "Transfer UNCESSFUL!" UPSECTION
DOS "DEL $REPPATH$REPFILE
GOTO LEAVE ;Change to ALLDONE if
; auto logoff is set to no
;--------------------------- Lets get out of Here ----------------------
LEAVE: ;In case you have
WAITFOR "Thank you for calling" ;auto logoff set to
PAUSE 100 ;yes
SEND "ATZ^M^~^~^~^~^~^~ATH1M0^M" ;
SYSTEM Y ;
EXIT
ALLDONE:
SEND "^M"
WAITFOR "wcMAIL COMMAND"
DELAY 100
SEND "G^M"
PAUSE 5000
GETOUT:
HANGUP
SEND "ATZ^M^~^~^~^~^~^~ATH1M0^M"
SYSTEM Y
EXIT